add_library(scintilla STATIC
    qt/ScintillaEditBase/PlatQt.cpp
    qt/ScintillaEditBase/ScintillaQt.cpp
    qt/ScintillaEditBase/ScintillaEditBase.cpp
    src/XPM.cxx
    src/ViewStyle.cxx
    src/UniqueString.cxx
    src/UniConversion.cxx
    src/UndoHistory.cxx
    src/Style.cxx
    src/Selection.cxx
    src/ScintillaBase.cxx
    src/RunStyles.cxx
    src/RESearch.cxx
    src/PositionCache.cxx
    src/PerLine.cxx
    src/MarginView.cxx
    src/LineMarker.cxx
    src/KeyMap.cxx
    src/Indicator.cxx
    src/Geometry.cxx
    src/EditView.cxx
    src/Editor.cxx
    src/EditModel.cxx
    src/Document.cxx
    src/Decoration.cxx
    src/DBCS.cxx
    src/ContractionState.cxx
    src/CharClassify.cxx
    src/CharacterType.cxx
    src/CharacterCategoryMap.cxx
    src/ChangeHistory.cxx
    src/CellBuffer.cxx
    src/CaseFolder.cxx
    src/CaseConvert.cxx
    src/CallTip.cxx
    src/AutoComplete.cxx
    qt/ScintillaEditBase/PlatQt.h
    qt/ScintillaEditBase/ScintillaQt.h
    qt/ScintillaEditBase/ScintillaEditBase.h
    src/XPM.h
    src/ViewStyle.h
    src/UndoHistory.h
    src/UniConversion.h
    src/Style.h
    src/SplitVector.h
    src/Selection.h
    src/ScintillaBase.h
    src/RunStyles.h
    src/RESearch.h
    src/PositionCache.h
    src/Platform.h
    src/PerLine.h
    src/Partitioning.h
    src/LineMarker.h
    src/KeyMap.h
    src/Indicator.h
    src/Geometry.h
    src/Editor.h
    src/Document.h
    src/Decoration.h
    src/ContractionState.h
    src/CharClassify.h
    src/CharacterType.h
    src/CharacterCategoryMap.h
    src/ChangeHistory.h
    src/CellBuffer.h
    src/CaseFolder.h
    src/CaseConvert.h
    src/CallTip.h
    src/AutoComplete.h
    include/Scintilla.h
    include/ILexer.h
    qt/ScintillaEdit/ScintillaEdit.cpp
    qt/ScintillaEdit/ScintillaDocument.cpp
    qt/ScintillaEdit/ScintillaEdit.h
    qt/ScintillaEdit/ScintillaDocument.h
)

target_link_libraries(scintilla PRIVATE Qt${QT_VERSION_MAJOR}::Widgets Qt${QT_VERSION_MAJOR}::Core Qt${QT_VERSION_MAJOR}::Core5Compat)
